{% extends 'base_main.html' %}
{% block ext_css %}
    {{ super() }}
    <link rel="stylesheet" href="{{ url_for('static',filename='app/cart/cart.css',_external=True) }}">
{% endblock %}
{% block ext_js %}
    {{ super() }}
    <script type="text/javascript" src="{{ url_for('static',filename='app/cart/js/cart.js') }}"></script>
{% endblock %}
{% block content %}
    <div id="cart">
        <h3>购物车</h3>
        <div class="full">
            <section>
                <ul>
                    <li>收货人：</li>
                    <li>电&nbsp;&nbsp;&nbsp;话：</li>
                    <li>地&nbsp&nbsp&nbsp址：</li>
                </ul>

                <div class="bill">
                    <p>闪购超市</p>
                    <p>0元起送满30元免运费22:00前送达</p>
                    <a href="">凑单专区</a>
                </div>
                <div class="delivery">
                    <span>收货时间</span>
                    <span>一小时内送达</span>
                    <a href="">可预订&gt;&gt;</a>
                </div>
                <div class="delivery">
                    <span>收货备注：</span>
                    <input type="text" placeholder="可输入100字内的备注信息">
                </div>
                <ul>
                    {% for cart in context.carts %}
                        <li class="menuList" cartid="{{ cart.id }} ">
                            <div class="confirm" is_select="{{ cart.is_select }}">
                                <span>
                                    {% if cart.is_select %}
                                        √
                                    {% else %}

                                    {% endif %}
                                    <span></span>
                                </span>
                            </div>
                            <a href="">
                                <img src="{{ cart.goods.productimg }}" alt="{{ cart.goods.productlongname }}">
                                <p>{{ cart.goods.productlongname }}</p>
                                <p class="presentPrice">{{ cart.goods.price }}</p>
                            </a>
                            <section>
                                <button class="subShopping">-</button>
                                <span>{{ cart.c_num }}</span>
                                <button class="addShopping">+</button>
                            </section>
                        </li>
                    {% endfor %}
                </ul>
                <div class="payTheBill">
                    <div class="all_select">
                        {% if context.is_all_select %}
                            <span>√</span>
                        {% else %}
                            <span></span>
                        {% endif %}
                    </div>
                    <p>
                        <span>全选</span>
                        <span>共计：</span>
                        <span id="result">{{ context.result }}</span>
                    </p>
                    <span id="generate_order">下单</span>
                </div>
            </section>
        </div>
    </div>

{% endblock %}